<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
<style>
body{
font-family:consolas;
font-size:15px;
}
div{
margin:2px;
}
</style>
</head>
<body>
<div style="background:gold;border:1px solid black;padding:3px;width:150px;">
<span style="border:2px dotted;">text1</span><div style="display:none;">div</div> <span
style="border:2px dotted;">text2</span>
</div>
<div style="background:gold;border:1px solid black;padding:3px;width:150px;">
<span style="border:2px dotted;">text1</span><div style="display:none;">div</div> <div style="display:none;">div</div><span style="border:2px dotted;">text2</span>
</div>
<div style="background:gold;border:1px solid black;padding:3px;width:150px;">
<span style="border:2px dotted;">text1</span><div style="display:none;">div</div> <div style="display:none;">div</div> <span style="border:2px dotted;">text2</span>
</div>
<br />
<div style="background:gold;border:1px solid black;padding:3px;width:150px;">
<span style="border:2px dotted;">text1</span> <span style="display:none;">span</span> <span style="display:none;">span</span><span style="border:2px dotted;">text2</span>
</div>
<div style="background:gold;border:1px solid black;padding:3px;width:150px;">
<span style="border:2px dotted;">text1</span> <input type="hidden" /> <input type="hidden" /><span style="border:2px dotted;">text2</span>
</div>
<div style="background:gold;border:1px solid black;padding:3px;width:150px;">
<span style="border:2px dotted;">text1</span><span style="display:none;">span</span> <span style="display:none;">span</span> <span style="border:2px dotted;">text2</span>
</div>
<div style="background:gold;border:1px solid black;padding:3px;width:150px;">
<span style="border:2px dotted;">text1</span><input type="hidden" /> <input type="hidden" /> <span style="border:2px dotted;">text2</span>
</div>
<br />
<div style="background:gold;border:1px solid black;padding:3px;width:150px;">
<span style="border:2px dotted;">text1</span> <span style="display:none;">span</span> <span  style="display:none;">span</span> <span style="border:2px dotted;">text2</span>
</div>
<div style="background:gold;border:1px solid black;padding:3px;width:150px;">
<span style="border:2px dotted;">text1</span> <input type="hidden" /> <input type="hidden" /> <span style="border:2px dotted;">text2</span>
</div>
</body>
</html>